using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes.DomainAttributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Enums;
using System.Collections.Generic;
using System.ComponentModel;

namespace Baci.ArcGIS._AnalysisTools._Proximity
{
    /// <summary>
    /// <para>Polygon Neighbors</para>
    /// <para>Creates a table with statistics based on polygon contiguity (overlaps, coincident edges, or nodes).</para>
    /// <para>创建一个包含基于面连续性（重叠、重合边或节点）的统计信息的表。</para>
    /// </summary>    
    [DisplayName("Polygon Neighbors")]
    public class PolygonNeighbors : AbstractGPProcess
    {
        /// <summary>
        /// 无参构造
        /// </summary>
        public PolygonNeighbors()
        {

        }

        /// <summary>
        /// 有参构造
        /// </summary>
        /// <param name="_in_features">
        /// <para>Input Features</para>
        /// <para>The input polygon features.</para>
        /// <para>输入面要素。</para>
        /// </param>
        /// <param name="_out_table">
        /// <para>Output Table</para>
        /// <para>The output table.</para>
        /// <para>输出表。</para>
        /// </param>
        public PolygonNeighbors(object _in_features, object _out_table)
        {
            this._in_features = _in_features;
            this._out_table = _out_table;
        }
        public override string ToolboxName => "Analysis Tools";

        public override string ToolName => "Polygon Neighbors";

        public override string CallName => "analysis.PolygonNeighbors";

        public override List<string> AcceptEnvironments => ["autoCommit", "extent", "qualifiedFieldNames", "scratchWorkspace", "workspace"];

        public override object[] ParameterInfo => [_in_features, _out_table, _in_fields, _area_overlap.GetGPValue(), _both_sides.GetGPValue(), _cluster_tolerance, _out_linear_units.GetGPValue(), _out_area_units.GetGPValue()];

        /// <summary>
        /// <para>Input Features</para>
        /// <para>The input polygon features.</para>
        /// <para>输入面要素。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Input Features")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _in_features { get; set; }


        /// <summary>
        /// <para>Output Table</para>
        /// <para>The output table.</para>
        /// <para>输出表。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Output Table")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _out_table { get; set; }


        /// <summary>
        /// <para>Report By Field(s)</para>
        /// <para>The input attribute field or fields that will be used to identify unique polygons or polygon groups and represent them in the output.</para>
        /// <para>将用于标识唯一面或面组并在输出中表示它们的一个或多个输入属性字段。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Report By Field(s)")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public List<object> _in_fields { get; set; } = null;


        /// <summary>
        /// <para>Include area overlaps</para>
        /// <para><xdoc>
        ///   <para>Specifies whether overlapping area relationships will be analyzed and included in the output.
        ///   <bulletList>
        ///     <bullet_item>Unchecked—Overlapping relationships will not be analyzed or included in the output. This is the default.  </bullet_item><para/>
        ///     <bullet_item>Checked—Overlapping relationships will be analyzed and included in the output.  </bullet_item><para/>
        ///   </bulletList>
        ///   </para>
        /// </xdoc></para>
        /// <para><xdoc>
        /// <para>指定是否分析重叠面积关系并将其包含在输出中。
        ///   <bulletList>
        ///     <bullet_item>未选中 - 不会分析重叠关系，也不会将其包含在输出中。这是默认设置。 </bullet_item><para/>
        ///     <bullet_item>选中 - 将分析重叠关系并将其包含在输出中。</bullet_item><para/>
        ///   </bulletList>
        ///   </para>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Include area overlaps")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public _area_overlap_value _area_overlap { get; set; } = _area_overlap_value._false;

        public enum _area_overlap_value
        {
            /// <summary>
            /// <para>AREA_OVERLAP</para>
            /// <para></para>
            /// <para></para>
            /// </summary>
            [Description("AREA_OVERLAP")]
            [GPEnumValue("true")]
            _true,

            /// <summary>
            /// <para>NO_AREA_OVERLAP</para>
            /// <para></para>
            /// <para></para>
            /// </summary>
            [Description("NO_AREA_OVERLAP")]
            [GPEnumValue("false")]
            _false,

        }

        /// <summary>
        /// <para>Include both sides of neighbor relationship</para>
        /// <para><xdoc>
        ///   <para>Specifies whether both sides of neighbor relationships will be included in the output.
        ///   <bulletList>
        ///     <bullet_item>Checked—For a pair of neighboring polygons, both neighboring information of one polygon being the source and the other being the neighbor and vice versa will be included. This is the default.  </bullet_item><para/>
        ///     <bullet_item>Unchecked—For a pair of neighboring polygons, only neighboring information of one polygon being the source and the other being the neighbor will be included. The reciprocal relationship will not be included.  </bullet_item><para/>
        ///   </bulletList>
        ///   </para>
        /// </xdoc></para>
        /// <para><xdoc>
        /// <para>指定是否将邻居关系的两端都包含在输出中。
        ///   <bulletList>
        ///     <bullet_item>选中 - 对于一对相邻面，将包括一个面为源，另一个面为邻面的相邻信息，反之亦然。这是默认设置。 </bullet_item><para/>
        ///     <bullet_item>未选中 - 对于一对相邻面，将仅包括一个面为源，另一个面为相邻面的相邻信息。互惠关系将不包括在内。 </bullet_item><para/>
        ///   </bulletList>
        ///   </para>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Include both sides of neighbor relationship")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public _both_sides_value _both_sides { get; set; } = _both_sides_value._true;

        public enum _both_sides_value
        {
            /// <summary>
            /// <para>BOTH_SIDES</para>
            /// <para></para>
            /// <para></para>
            /// </summary>
            [Description("BOTH_SIDES")]
            [GPEnumValue("true")]
            _true,

            /// <summary>
            /// <para>NO_BOTH_SIDES</para>
            /// <para></para>
            /// <para></para>
            /// </summary>
            [Description("NO_BOTH_SIDES")]
            [GPEnumValue("false")]
            _false,

        }

        /// <summary>
        /// <para>XY Tolerance</para>
        /// <para><xdoc>
        ///   <para>The minimum distance between coordinates before they will be considered equal. By default, this is the x,y tolerance of the input features.</para>
        ///   <para>Changing this parameter's value may cause failure or unexpected results. It is recommended that this parameter not be modified. It has been removed from view in the tool dialog. By default, the input feature class's spatial reference x,y tolerance property is used.</para>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>坐标之间的最小距离，然后才被视为相等。默认情况下，这是输入要素的 x，y 容差。</para>
        ///   <para>更改此参数的值可能会导致失败或意外结果。建议不要修改该参数。它已从工具对话框的视图中删除。默认情况下，将使用输入要素类的空间参考 x，y 容差属性。</para>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("XY Tolerance")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public string? _cluster_tolerance { get; set; } = null;


        /// <summary>
        /// <para>Output Linear Units</para>
        /// <para><xdoc>
        ///   <para>Specifies the units that will be used to report the total length of the coincident edge between neighboring polygons. The default is the input feature units.</para>
        ///   <bulletList>
        ///     <bullet_item>Unknown—The units will be unknown.</bullet_item><para/>
        ///     <bullet_item>Inches—The units will be inches.</bullet_item><para/>
        ///     <bullet_item>Feet—The units will be feet.</bullet_item><para/>
        ///     <bullet_item>Yards—The units will be yards.</bullet_item><para/>
        ///     <bullet_item>Miles—The units will be miles.</bullet_item><para/>
        ///     <bullet_item>Nautical miles—The units will be nautical miles.</bullet_item><para/>
        ///     <bullet_item>Millimeters—The units will be millimeters.</bullet_item><para/>
        ///     <bullet_item>Centimeters—The units will be centimeters.</bullet_item><para/>
        ///     <bullet_item>Decimeters—The units will be decimeters.</bullet_item><para/>
        ///     <bullet_item>Meters—The units will be meters.</bullet_item><para/>
        ///     <bullet_item>Kilometers—The units will be kilometers.</bullet_item><para/>
        ///     <bullet_item>Decimal degrees—The units will be decimal degrees.</bullet_item><para/>
        ///     <bullet_item>Points—The units will be points.</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>指定将用于报告相邻多边形之间重合边的总长度的单位。默认值为输入要素单位。</para>
        ///   <bulletList>
        ///     <bullet_item>未知—单位将未知。</bullet_item><para/>
        ///     <bullet_item>英寸—单位将为英寸。</bullet_item><para/>
        ///     <bullet_item>英尺—单位将为英尺。</bullet_item><para/>
        ///     <bullet_item>码—单位将为码。</bullet_item><para/>
        ///     <bullet_item>英里—单位为英里。</bullet_item><para/>
        ///     <bullet_item>海里—单位为海里。</bullet_item><para/>
        ///     <bullet_item>毫米—单位将为毫米。</bullet_item><para/>
        ///     <bullet_item>厘米—单位将为厘米。</bullet_item><para/>
        ///     <bullet_item>分米—单位将为分米。</bullet_item><para/>
        ///     <bullet_item>米—单位为米。</bullet_item><para/>
        ///     <bullet_item>千米—单位将为千米。</bullet_item><para/>
        ///     <bullet_item>十进制度—单位为十进制度。</bullet_item><para/>
        ///     <bullet_item>点—单位将为点。</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Output Linear Units")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public _out_linear_units_value _out_linear_units { get; set; } = _out_linear_units_value._UNKNOWN;

        public enum _out_linear_units_value
        {
            /// <summary>
            /// <para>Unknown</para>
            /// <para>Unknown—The units will be unknown.</para>
            /// <para>未知—单位将未知。</para>
            /// </summary>
            [Description("Unknown")]
            [GPEnumValue("UNKNOWN")]
            _UNKNOWN,

            /// <summary>
            /// <para>Inches</para>
            /// <para>Inches—The units will be inches.</para>
            /// <para>英寸—单位将为英寸。</para>
            /// </summary>
            [Description("Inches")]
            [GPEnumValue("INCHES")]
            _INCHES,

            /// <summary>
            /// <para>Points</para>
            /// <para>Points—The units will be points.</para>
            /// <para>点—单位将为点。</para>
            /// </summary>
            [Description("Points")]
            [GPEnumValue("POINTS")]
            _POINTS,

            /// <summary>
            /// <para>Feet</para>
            /// <para>Feet—The units will be feet.</para>
            /// <para>英尺—单位将为英尺。</para>
            /// </summary>
            [Description("Feet")]
            [GPEnumValue("FEET")]
            _FEET,

            /// <summary>
            /// <para>Yards</para>
            /// <para>Yards—The units will be yards.</para>
            /// <para>码—单位将为码。</para>
            /// </summary>
            [Description("Yards")]
            [GPEnumValue("YARDS")]
            _YARDS,

            /// <summary>
            /// <para>Miles</para>
            /// <para>Miles—The units will be miles.</para>
            /// <para>英里—单位为英里。</para>
            /// </summary>
            [Description("Miles")]
            [GPEnumValue("MILES")]
            _MILES,

            /// <summary>
            /// <para>Nautical miles</para>
            /// <para>Nautical miles—The units will be nautical miles.</para>
            /// <para>海里—单位为海里。</para>
            /// </summary>
            [Description("Nautical miles")]
            [GPEnumValue("NAUTICAL_MILES")]
            _NAUTICAL_MILES,

            /// <summary>
            /// <para>Millimeters</para>
            /// <para>Millimeters—The units will be millimeters.</para>
            /// <para>毫米—单位将为毫米。</para>
            /// </summary>
            [Description("Millimeters")]
            [GPEnumValue("MILLIMETERS")]
            _MILLIMETERS,

            /// <summary>
            /// <para>Centimeters</para>
            /// <para>Centimeters—The units will be centimeters.</para>
            /// <para>厘米—单位将为厘米。</para>
            /// </summary>
            [Description("Centimeters")]
            [GPEnumValue("CENTIMETERS")]
            _CENTIMETERS,

            /// <summary>
            /// <para>Meters</para>
            /// <para>Meters—The units will be meters.</para>
            /// <para>米—单位为米。</para>
            /// </summary>
            [Description("Meters")]
            [GPEnumValue("METERS")]
            _METERS,

            /// <summary>
            /// <para>Kilometers</para>
            /// <para>Kilometers—The units will be kilometers.</para>
            /// <para>千米—单位将为千米。</para>
            /// </summary>
            [Description("Kilometers")]
            [GPEnumValue("KILOMETERS")]
            _KILOMETERS,

            /// <summary>
            /// <para>Decimeters</para>
            /// <para>Decimeters—The units will be decimeters.</para>
            /// <para>分米—单位将为分米。</para>
            /// </summary>
            [Description("Decimeters")]
            [GPEnumValue("DECIMETERS")]
            _DECIMETERS,

            /// <summary>
            /// <para>Decimal degrees</para>
            /// <para>Decimal degrees—The units will be decimal degrees.</para>
            /// <para>十进制度—单位为十进制度。</para>
            /// </summary>
            [Description("Decimal degrees")]
            [GPEnumValue("DECIMAL_DEGREES")]
            _DECIMAL_DEGREES,

        }

        /// <summary>
        /// <para>Output Area Units</para>
        /// <para><xdoc>
        ///   <para>Specifies the units that will be used to report the area overlap of neighboring polygons. The default is the input feature units. This parameter is only active when the Include area overlaps parameter is checked.</para>
        ///   <bulletList>
        ///     <bullet_item>Unknown—The units will be unknown.</bullet_item><para/>
        ///     <bullet_item>Ares—The units will be ares.</bullet_item><para/>
        ///     <bullet_item>Acres—The units will be acres.</bullet_item><para/>
        ///     <bullet_item>Hectares—The units will be hectares.</bullet_item><para/>
        ///     <bullet_item>Square inches—The units will be square inches.</bullet_item><para/>
        ///     <bullet_item>Square feet—The units will be square feet.</bullet_item><para/>
        ///     <bullet_item>Square yards—The units will be square yards.</bullet_item><para/>
        ///     <bullet_item>Square miles—The units will be square miles.</bullet_item><para/>
        ///     <bullet_item>Square millimeters—The units will be square millimeters.</bullet_item><para/>
        ///     <bullet_item>Square centimeters—The units will be square centimeters.</bullet_item><para/>
        ///     <bullet_item>Square decimeters—The units will be square decimeters.</bullet_item><para/>
        ///     <bullet_item>Square meters—The units will be square meters.</bullet_item><para/>
        ///     <bullet_item>Square kilometers—The units will be square kilometers.</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>指定将用于报告相邻多边形的面积重叠的单位。默认值为输入要素单位。仅当选中“包括面积重叠”参数时，此参数才处于活动状态。</para>
        ///   <bulletList>
        ///     <bullet_item>未知—单位将未知。</bullet_item><para/>
        ///     <bullet_item>Ares—单位将为 ares。</bullet_item><para/>
        ///     <bullet_item>英亩—单位为英亩。</bullet_item><para/>
        ///     <bullet_item>公顷—单位将为公顷。</bullet_item><para/>
        ///     <bullet_item>平方英寸—单位将为平方英寸。</bullet_item><para/>
        ///     <bullet_item>平方英尺—单位将为平方英尺。</bullet_item><para/>
        ///     <bullet_item>平方码—单位将为平方码。</bullet_item><para/>
        ///     <bullet_item>平方英里—单位将为平方英里。</bullet_item><para/>
        ///     <bullet_item>平方毫米—单位将为平方毫米。</bullet_item><para/>
        ///     <bullet_item>平方厘米—单位将为平方厘米。</bullet_item><para/>
        ///     <bullet_item>平方分米—单位将为平方分米。</bullet_item><para/>
        ///     <bullet_item>平方米—单位将为平方米。</bullet_item><para/>
        ///     <bullet_item>平方公里—单位将为平方千米。</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Output Area Units")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public _out_area_units_value _out_area_units { get; set; } = _out_area_units_value._UNKNOWN;

        public enum _out_area_units_value
        {
            /// <summary>
            /// <para>Unknown</para>
            /// <para>Unknown—The units will be unknown.</para>
            /// <para>未知—单位将未知。</para>
            /// </summary>
            [Description("Unknown")]
            [GPEnumValue("UNKNOWN")]
            _UNKNOWN,

            /// <summary>
            /// <para>Square inches</para>
            /// <para>Square inches—The units will be square inches.</para>
            /// <para>平方英寸—单位将为平方英寸。</para>
            /// </summary>
            [Description("Square inches")]
            [GPEnumValue("SQUARE_INCHES")]
            _SQUARE_INCHES,

            /// <summary>
            /// <para>Square feet</para>
            /// <para>Square feet—The units will be square feet.</para>
            /// <para>平方英尺—单位将为平方英尺。</para>
            /// </summary>
            [Description("Square feet")]
            [GPEnumValue("SQUARE_FEET")]
            _SQUARE_FEET,

            /// <summary>
            /// <para>Square yards</para>
            /// <para>Square yards—The units will be square yards.</para>
            /// <para>平方码—单位将为平方码。</para>
            /// </summary>
            [Description("Square yards")]
            [GPEnumValue("SQUARE_YARDS")]
            _SQUARE_YARDS,

            /// <summary>
            /// <para>Acres</para>
            /// <para>Acres—The units will be acres.</para>
            /// <para>英亩—单位为英亩。</para>
            /// </summary>
            [Description("Acres")]
            [GPEnumValue("ACRES")]
            _ACRES,

            /// <summary>
            /// <para>Square miles</para>
            /// <para>Square miles—The units will be square miles.</para>
            /// <para>平方英里—单位将为平方英里。</para>
            /// </summary>
            [Description("Square miles")]
            [GPEnumValue("SQUARE_MILES")]
            _SQUARE_MILES,

            /// <summary>
            /// <para>Square millimeters</para>
            /// <para>Square millimeters—The units will be square millimeters.</para>
            /// <para>平方毫米—单位将为平方毫米。</para>
            /// </summary>
            [Description("Square millimeters")]
            [GPEnumValue("SQUARE_MILLIMETERS")]
            _SQUARE_MILLIMETERS,

            /// <summary>
            /// <para>Square decimeters</para>
            /// <para>Square decimeters—The units will be square decimeters.</para>
            /// <para>平方分米—单位将为平方分米。</para>
            /// </summary>
            [Description("Square decimeters")]
            [GPEnumValue("SQUARE_DECIMETERS")]
            _SQUARE_DECIMETERS,

            /// <summary>
            /// <para>Square centimeters</para>
            /// <para>Square centimeters—The units will be square centimeters.</para>
            /// <para>平方厘米—单位将为平方厘米。</para>
            /// </summary>
            [Description("Square centimeters")]
            [GPEnumValue("SQUARE_CENTIMETERS")]
            _SQUARE_CENTIMETERS,

            /// <summary>
            /// <para>Square meters</para>
            /// <para>Square meters—The units will be square meters.</para>
            /// <para>平方米—单位将为平方米。</para>
            /// </summary>
            [Description("Square meters")]
            [GPEnumValue("SQUARE_METERS")]
            _SQUARE_METERS,

            /// <summary>
            /// <para>Square kilometers</para>
            /// <para>Square kilometers—The units will be square kilometers.</para>
            /// <para>平方公里—单位将为平方千米。</para>
            /// </summary>
            [Description("Square kilometers")]
            [GPEnumValue("SQUARE_KILOMETERS")]
            _SQUARE_KILOMETERS,

            /// <summary>
            /// <para>Ares</para>
            /// <para>Ares—The units will be ares.</para>
            /// <para>Ares—单位将为 ares。</para>
            /// </summary>
            [Description("Ares")]
            [GPEnumValue("ARES")]
            _ARES,

            /// <summary>
            /// <para>Hectares</para>
            /// <para>Hectares—The units will be hectares.</para>
            /// <para>公顷—单位将为公顷。</para>
            /// </summary>
            [Description("Hectares")]
            [GPEnumValue("HECTARES")]
            _HECTARES,

        }

        public PolygonNeighbors SetEnv(int? autoCommit = null, object extent = null, bool? qualifiedFieldNames = null, object scratchWorkspace = null, object workspace = null)
        {
            base.SetEnv(autoCommit: autoCommit, extent: extent, qualifiedFieldNames: qualifiedFieldNames, scratchWorkspace: scratchWorkspace, workspace: workspace);
            return this;
        }

    }

}